package Com.amit.Thread;

public class Lab6  extends Thread{
	
	@Override
	public void run() {
		
		for(int i=1;i<=5;i++)
		{
			try
			{
				Thread.sleep(500);
			}
			catch (Exception e) {
				
			}
			
			System.out.println(i);
		}
	}
	
	public static void main(String[] args) {
		
		Lab6 t1=new Lab6();
		
		Lab6 t2=new Lab6();
		
		Lab6 t3=new Lab6();
		
		t1.start();
		try
		{
		t1.join(15000);
		}
		catch (Exception e) 
		{
			System.out.println(e);
		}
		t2.start();
		t3.start();
		
		
	}

}
